package com.cn.algorithm02.class04;

/***
 * @author: hels
 * @description:
 **/
public class Node {
    int value;
    Node next;
    public Node(int value){
        this.value = value;
    }

    public static Node getHead() {
        Node node1 = new Node(1);
        Node node2 = new Node(2);
        Node node3 = new Node(3);
        node1.next = node2;
        node2.next = node3;
        return node1;
    }

    @Override
    public String toString() {
        return "Nodea{" +
                "value=" + value +
                ", next=" + next +
                '}';
    }
}
